import React from 'react';

class CommentListItem extends React.Component {
  render() {
    return (
      <ul>
        {this.props.commentList.map((item) => {
          return (
            <li key={item.id}>
              <h3>评论人：{item.name}</h3>
              <p>评论内容： {item.text}</p>
            </li>
          );
        })}
      </ul>
    );
  }
}

export default CommentListItem;
